package edu.nf.reservation.inf;

import edu.nf.reservation.dto.ReservationDTO;
import edu.nf.reservation.dto.ReservationPageDTO;

import java.util.List;

/**
 * @author Lv
 * @date 2022/3/29
 */
public interface ReservationService {

    /**
     * 查询所有预约
     * @param reservationDTO
     * @param pageNum
     * @param pageSize
     * @return
     */
    ReservationPageDTO listReservation(ReservationDTO reservationDTO,Integer pageNum,Integer pageSize);

    /**
     * 新增预约
     * @param reservationDTO
     */
    void addReservation(ReservationDTO reservationDTO) throws Exception;

    /**
     * 移除预约
     * @param reservationId
     */
    void delReservation(int reservationId);

    /**
     * 根据ID查询预约详情
     * @return
     */
    ReservationDTO selectById(Integer reservation);

    /**
     * 根据用户ID查询某条预约记录
     * @param uid
     * @return
     */
    List<ReservationDTO> listReservationByUserId(Integer uid);
}
